﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="policyData.aspx.cs" Inherits="AutoInsurance.policyData" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <asp:Label ID="Label1" runat="server" Text="Все полисы"></asp:Label>
    <asp:GridView ID="GridView1" runat="server" onselectedindexchanged="GridView1_SelectedIndexChanged" DataKeyNames="id_policy" AutoGenerateColumns="False" >
                    <Columns>
            <asp:CommandField ShowSelectButton="True" ButtonType="Button" SelectText="Добавить страховой случай" />

                            <asp:BoundField DataField="id_policy" HeaderText="id_policy" SortExpression="id_policy" />
                <asp:BoundField DataField="vin_code" HeaderText="VIN-код" 
                    SortExpression="vin_code" />
                <asp:BoundField DataField="id_manager" HeaderText="id_manager" 
                    SortExpression="id_manager" />
                <asp:BoundField DataField="overdate" HeaderText="Дата окончания полиса" SortExpression="overdate" />
                <asp:BoundField DataField="isopen" HeaderText="Без ограничений" SortExpression="isopen" /> 
                <asp:BoundField DataField="type" HeaderText="Вид страхования" SortExpression="type" /> 
                <asp:BoundField DataField="totalsum" HeaderText="Стоимость полиса" SortExpression="totalsum" /> 
                <asp:BoundField DataField="giveout" HeaderText="Выдан" SortExpression="giveout" /> 
      </Columns>
      
</asp:GridView>
    <asp:Label ID="Label2" runat="server" Text="Невыданные полисы"></asp:Label>
<br />
    <asp:GridView ID="GridView2" runat="server" onselectedindexchanged="GridView2_SelectedIndexChanged" DataKeyNames="id_policy" AutoGenerateColumns="False" >
                        <Columns>
            <asp:CommandField ShowSelectButton="True" ButtonType="Button" SelectText="Выдать полис" />
                                        <asp:BoundField DataField="id_policy" HeaderText="id_policy" SortExpression="id_policy" />
                <asp:BoundField DataField="vin_code" HeaderText="VIN-код" 
                    SortExpression="vin_code" />
                <asp:BoundField DataField="id_manager" HeaderText="id_manager" 
                    SortExpression="id_manager" />
                <asp:BoundField DataField="overdate" HeaderText="Дата окончания полиса" SortExpression="overdate" />
                <asp:BoundField DataField="isopen" HeaderText="Без ограничений" SortExpression="isopen" /> 
                <asp:BoundField DataField="type" HeaderText="Вид страхования" SortExpression="type" /> 
                <asp:BoundField DataField="totalsum" HeaderText="Стоимость полиса" SortExpression="totalsum" /> 
                <asp:BoundField DataField="giveout" HeaderText="Выдан" SortExpression="giveout" /> 
      </Columns>
    </asp:GridView>
</asp:Content>
